<!DOCTYPE html>
<html>
<head>
  <title>LIBRARY</title> 	 
	<%= stylesheet_link_tag "application", :media => "all" %>
	<%= javascript_include_tag "application"%>
	<%= %>
    <%= csrf_meta_tag %>
</head>
<body>
	
	<div id = "wapper">
		<div id = "header">
			<!--phan cu-->
			<div id="banner">
				<%= @page_tiltle || "University of Technology" %><br />
			</div>
	
    
<!--sss-->
		<div id='cssmenu'>
		<ul>
		   <li><a href='#'><span><%= link_to'Home' , home_path %></span></a></li> 
		   <li><a href='#'><span>About</span></a></li>
		   <li><a href='#'><span>Contact</span></a></li>
		   <li><a href='#'><span>
		   		<% if session[:user_id] %>
	        		<%= link_to 'Logout', logout_path, :method => :delete %>
	      		<% else %>
	      	  		<%= link_to 'Login', login_path %>
	      		<% end %>
		   	</span></a></li>
		</ul>
		</div>
		
		
		<!--het phan cu-->
		
		<div id = "sidebar">
			<h3 id="navi">Menu</h3>
			<ul id = "namenu">
				<li>
					<%= link_to "Home", home_path %>
				</li>
				<li>
					<%= link_to "Search document", search_document_info_path %>
				</li>
				
				<% if session[:user_id] and session[:user_type] == 'student'%>
					<li><%= link_to "Account", student_info_path %></li>
				<% end %>
				
				<% if session[:user_id] and session[:user_type] == 'librarian'%>
					<li><%= link_to "Document", documents_path %></li>
					<li><%= link_to "Borrowing", borrowings_path %></li>
					<li><%= link_to "Document Return",  document_return_path%></li>
				<% end %>
				
			</ul>
		</div>
		
		</div>
		<div id = "content">
			<div id="main">
			<%= yield %>
		</div>
		
		<div id = "footer">
			
		</div>
	</div>
	
	
		
</body>
</html>

